<?php
/**
 * Created by PhpStorm.
 * User: 陈艺赫
 * Date: 2017/12/7
 * Time: 0:57
 */

namespace Home\Controller;

class GongshangController extends BaseController
{
    public function index(){
        $db_file = M('file');
        $data_file1 = $db_file->where('status = 1 and cat_id = 1')->select();
        $data_file2 = $db_file->where('status = 1 and cat_id = 2')->select();
        $data_file3 = $db_file->where('status = 1 and cat_id = 3')->select();
        $data_file4 = $db_file->where('status = 1 and cat_id = 4')->select();
        $data_file5 = $db_file->where('status = 1 and cat_id = 5')->select();
        $data_file6 = $db_file->where('status = 1 and cat_id = 6')->select();
        $data_file7 = $db_file->where('status = 1 and cat_id = 7')->select();
        $data_file8 = $db_file->where('status = 1 and cat_id = 8')->select();
        $data_file9 = $db_file->where('status = 1 and cat_id = 9')->select();
        $data_file10 = $db_file->where('status = 1 and cat_id = 10')->select();
        $data_file11 = $db_file->where('status = 1 and cat_id = 11')->select();
        $this->assign('file1',$data_file1);
        $this->assign('file2',$data_file2);
        $this->assign('file3',$data_file3);
        $this->assign('file4',$data_file4);
        $this->assign('file5',$data_file5);
        $this->assign('file6',$data_file6);
        $this->assign('file7',$data_file7);
        $this->assign('file8',$data_file8);
        $this->assign('file9',$data_file9);
        $this->assign('file10',$data_file10);
        $this->assign('file11',$data_file11);
        $this->display();
    }

}